<!DOCTYPE html>
<html lang="en">

<head>
    <!-- Use correct character set. -->
    <meta charset="utf-8">
    <!-- Tell IE to use the latest, best version. -->
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <!-- Make the application on mobile take up the full browser screen and disable user scaling. -->
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no">
    <title>Hello World!</title>
    <!-- <script src="../Build/Cesium/Cesium.js"></script> -->
    <script src="./Cesium1.74/Cesium.js"></script>
    <style>
        /* @import url(../Build/Cesium/Widgets/widgets.css); */
        
        @import url(./Cesium1.74/Widgets/widgets.css);
        html,
        body,
        #cesiumContainer {
            width: 100%;
            height: 100%;
            margin: 0;
            padding: 0;
            overflow: hidden;
        }
        
        .compass {
            position: absolute;
            left: 0;
            top: 10px;
        }
        
        .navigation-controls {
            position: absolute;
            left: 30px;
            top: 120px;
            height: 90px;
        }
    </style>
</head>

<body>
    <div id="credit"></div>
    <div id="cesiumContainer">
        <div id="cesiumxin" style="position:fixed;left:0;z-index:99"><a href="http://cesium.xin" style="color:aliceblue;text-decoration:none">cesium中文网 http://cesium.xin </a></div>
    </div>
    <script src="./cesium-navigation/viewerCesiumNavigationMixin.min.js"></script>
    <script>
        var viewer = new Cesium.Viewer('cesiumContainer', {
            imageryProvider: new Cesium.SingleTileImageryProvider({
                url: '../img/worldimage.jpg'
            }),
            //geocoder: false,
            homeButton: false,
            sceneModePicker: false,
            baseLayerPicker: false,
            navigationHelpButton: false,
            animation: false,
            creditContainer: "credit",
            timeline: false,
            fullscreenButton: false,
            vrButton: false
        });

        // extend our view by the cesium navigation mixin
        // viewer.extend(Cesium.viewerCesiumNavigationMixin, {});

        // Cesium.viewerCesiumNavigationMixin(viewer, {
        //     defaultResetView: Cesium.Rectangle.fromDegrees(71, 3, 90, 14),
        //     enableCompass: false,
        //     enableZoomControls: false,
        //     enableDistanceLegend: false,
        //     enableCompassOuterRing: false
        // });

        var options = {};
        options.defaultResetView = Cesium.Rectangle.fromDegrees(71, 3, 90, 14);
        // Only the compass will show on the map
        options.enableCompass = true;
        options.enableZoomControls = true;
        options.enableDistanceLegend = true;
        options.enableCompassOuterRing = true;
        viewer.extend(Cesium.viewerCesiumNavigationMixin, options);
        
        //重置视图按钮
        viewer.scene.camera.flyTo({
            destination: Cesium.Cartesian3.fromDegrees(101.88, 39.78, 10000000)
        });
    </script>
</body>